import { FC, ReactNode } from 'react';
import { Layout } from 'antd';
import HeaderNav from './HeaderNav';
import SideMenu from './SideMenu';
import styles from './MainLayout.module.css';

const { Content } = Layout;

interface MainLayoutProps {
  children: ReactNode;
}

const MainLayout: FC<MainLayoutProps> = ({ children }) => {
  return (
    <Layout className={styles.layout}>
      <HeaderNav />
      <Layout>
        <SideMenu />
        <Content className={styles.content}>{children}</Content>
      </Layout>
    </Layout>
  );
};

export default MainLayout;
